package com.uwlaser.service.dto;


import com.uwlaser.domain.BaseParam;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.util.List;

/**
 * 扫码校验
 */
@Data
public class ScanCodeCheckBatchParam extends BaseParam {

    @ApiModelProperty("二维码列表")
    @NotEmpty(message = "二维码列表【qrCodes】不能为空")
    @Valid
    private List<QrCode> qrCodes;

    @ApiModelProperty("产品编号")
    @NotBlank(message = "产品编号【productCode】不能为空")
    private String productCode;

    @Data
    public class QrCode {

        @ApiModelProperty("二维码")
        @NotBlank(message = "二维码【qrCodes】不能为空")
        private String qrCode;

        @ApiModelProperty("工步编号")
        @NotBlank(message = "工步编号【stepCode】不能为空")
        private String stepCode;
    }

}
